Temporary fix for netif ring overflow, until we move
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Fri, 15 Jul 2005 08:22:18 +0000 (08:22 +0000)
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Fri, 15 Jul 2005 08:22:18 +0000 (08:22 +0000)
netfront/netback to grant tables.

xen/include/public/io/netif.h

index 35ac622758a55b85d90f88c7e3324b8f8cf89c88..821e9b18ea18849b0776f7e320da72ae9dca894b 100644 (file)
@@ -46,8 +46,18 @@ typedef u32 NETIF_RING_IDX;
 #define MASK_NETIF_RX_IDX(_i) ((_i)&(NETIF_RX_RING_SIZE-1))
 #define MASK_NETIF_TX_IDX(_i) ((_i)&(NETIF_TX_RING_SIZE-1))
 
+#ifdef __x86_64__
+/*
+ * This restriction can be lifted when we move netfront/netback to use
+ * grant tables. This will remove memory_t fields from the above structures
+ * and thus relax natural alignment restrictions.
+ */
+#define NETIF_TX_RING_SIZE 128
+#define NETIF_RX_RING_SIZE 128
+#else
 #define NETIF_TX_RING_SIZE 256
 #define NETIF_RX_RING_SIZE 256
+#endif
 
 /* This structure must fit in a memory page. */
 typedef struct netif_tx_interface {